﻿extern alias python;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using python.IronPython.Hosting;
using python.Microsoft.Scripting.Hosting;

namespace RuntimeHelloWorlds
{
	public class IronPythonHelloWorld
	{
		public void SayHelloWorld()
		{
			ScriptEngine pythonEngine 
				= python::IronPython.Hosting.Python.CreateEngine();

			var scriptScope = pythonEngine.CreateScope();

			pythonEngine.Operations.SetMember(scriptScope, "x", "Hello, World!");
			pythonEngine.Execute(@"
import clr
import System
System.Console.WriteLine(x + ' (IronPython Hosting)')", scriptScope);


		}
	}
}
